public class CalculateFine {

    public Integer Fine { get; set; }
    public Integer Fine2 {get; set; }
    public Integer diff { get; set; }
    //private final String o;
    Application__c a = new Application__c();
    public Application__c getProxyObject() { return a; }

    //Method to Calculate Fine
    public PageReference CFine() 
    {
        if(a.Fine_Calculation_Date__c != null)
        diff = a.Fine_Calculation_Date__c.daysBetween(Date.Today());
         system.debug(diff);
         IF(diff > 30){
         Fine2 = (diff - 30)*25;
         IF((diff > 30)&&(diff < 60)){
         Fine = 0;
         return null;
         }
         else {
         Fine = (diff - 60)*25;
         return null;
          }
          } 
          
         else {
          Fine = 0;
          Fine2 = 0;
          return null;
          }
          
         
    }
   
}